/**
 * @Author：小鹿爱吃鱼
 * @Date: 2025/5/3 21:08
 * @Description:
 */
public class 只出现一次的数字 {

    public static int singleNumber(int[] nums) {
        int param = 0;
        for(int i = 0; i < nums.length; i++){
            param = nums[i] ^ param;
        }
        return param;
    }


    public static void main(String[] args) {
        int i = singleNumber(new int[]{1, 1, 2, 2, 3});
        System.out.println(i);
    }


}
